

    <style>
        /* 打开宽度限制 */
        .popover {
            max-width: 90vw;
        }
    </style>
<div class="container-fluid" id="main">
	<div class="row clearfix">
		<div class="col-md-12 column" id="mainalert">
			<div class="alert alert-dismissable alert-info">
				<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
				<p></p>
			</div>
		</div>
	</div>


	<div class="ntDesktop">
		{if $isshow == 1}
	  	<div class="ntDesktop-head">配货界面（包装主管）</div>
	  	{/if}
		<div class="row" style="padding-top:0px">
			<div class="col-md-6">
				<ul class="nav nav-tabs">
					<li class="active" @click="clickGetList('list')">
						<a href="#list" data-toggle="tab">
							新订单 <span class="label label-info" v-show="navPromptNum.listNum > 0">{{navPromptNum.listNum}}</span>
						</a>
					</li>
					<li @click="clickGetList('process')">
						<a href="#process" data-toggle="tab">
							处理中 <span class="label label-info" v-show="navPromptNum.processNum > 0">{{navPromptNum.processNum}}</span>
						</a>
					</li>
					<li @click="clickGetList('pickup')">
						<a href="#pickup" data-toggle="tab">
							提货 <span class="label label-info" v-show="navPromptNum.pickupNum > 0">{{navPromptNum.pickupNum}}</span>
						</a>
					</li>
					<li @click="clickGetList('pause')">
						<a href="#pause" data-toggle="tab">
							暂停 <span class="label label-info" v-show="navPromptNum.pauseNum > 0">{{navPromptNum.pauseNum}}</span>
						</a>
					</li>
					<li @click="clickGetList('finish')">
						<a href="#finish" data-toggle="tab">
							已完成 <span class="label label-info" v-show="navPromptNum.finishNum > 0">{{navPromptNum.finishNum}}</span>
						</a>
					</li>
					<li @click="clickGetList('cancel')">
						<a href="#cancel" data-toggle="tab">
							取消 <span class="label label-info" v-show="navPromptNum.cancelNum > 0">{{navPromptNum.cancelNum}}</span>
						</a>
					</li>
				</ul>
			</div>
			{if $isshow==1}
			<div class="col-md-4">
				<button class="btn btn-default btn-checkbox" @click="myWork()">
					<input type="checkbox" class="form-input"> 只显示我的工作
				</button>
			</div>
			<div class="col-md-2 text-right" v-show="requestType == 'list'">
				<button class="btn btn-primary" data-toggle="modal"  @click="startProcess('','','','double')" v-if="auth_ids.indexOf(328) != -1">
					 <span class="fa fa-cogs"></span> 开始处理
				</button>
			</div>
			{/if}
		</div>

		<div class="row tab-content">

			<!-- 配货 加工 新订单 列表 -->	
			<div class="col-md-12 tab-pane active" id="list" v-if="requestType == 'list'">
				<table class="table table-striped table-hover ntTable">
					<thead>
						<tr>
							<th width="4%">订单号</th>
							<th width="4%">优先级</th>
							<th width="4%">时间</th>
							<th></th>
							<th width="20%">产品</th>
							<th>箱规</th>
							<th>数量</th>
							<th>库存</th>
							<th>备注</th>
							<th>对货员</th>
							<th>指令</th>
							<th>操作</th>
						</tr>
					</thead>
					<tbody>
						<template v-if="list != undefined && list.length > 0">
							<template v-for="(listItem,listIndex) in list">
								<tr v-for="(detailItem,detailIndex) in listItem.detail">
									<template v-if="detailIndex == 0">
										<td>{{listItem.sale_id}}</td>
									</template>
									<template v-else>
										<td></td>
									</template>
									
									<td align="center"><span class="label label-primary f-1">{{detailItem.priority}}</span></td>
									<td class="text-success main-list" :oldTime="detailItem.create_at"><b></b></td>
									
									<td align="center">{if $isshow == 1}<input type="checkbox" :priority="detailItem.priority" :value="detailIndex" name="newListCheckbox" :detail_id="detailItem.detail_id" :listIndex="listIndex" :detailIndex="detailIndex" :qty="detailItem.qty" :prochar_id='detailItem.proInfo.prochar_id' @click='newListCheckbox_select'>{/if}</td>
									
									<td>
										<div class="pro">
											<div class="pro-icon">
												<img :src="detailItem.proInfo.img_url" border="0" width="48px" height="48px">
											</div>
											<div class="pro-name">
												<small>{{formatUnit(detailItem.proInfo.prochar_id,'id') + (detailItem.proInfo.brand_name ? ' / ' + detailItem.proInfo.brand_name : '') + (detailItem.proInfo.model ? ' / ' + detailItem.proInfo.model :'' ) }}</small> <br />{{detailItem.proInfo.pro_name}}
											</div>
										</div>
									</td>
									<td align="right">
										{{formatUnit( detailItem.proInfo.prochar_qty,'CTN')}}<small class="unit">PCS/CTN</small><br>
										{{detailItem.proInfo.ctn_size}}<small class="unit">CM</small>
									</td>
									<td align="right">
										{{formatUnit( detailItem.qty,'PCS')}}<small class="unit">PCS</small>
									</td>
									<td>
										<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="成品位置" @mouseover="setpopper">
											库存
											<div class="content"  style="display: none;">
												<div style="width:20vw">
													<table class="table">
														<tbody>
															<tr v-for="(storeInfoItem,storeInfoIndex) in detailItem.storeInfo">
																<td>{{storeInfoItem.name}}</td>
																<td align="right">
																	{{formatUnit( storeInfoItem.qty,'PCS')}}<small class="unit">PCS</small>
																</td>
															</tr>
														</tbody>
													</table>
												</div>
											</div>
										</button>
									</td>
									<td>
										<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="备注位置" @mouseover="setpopper">
											备注
											<div class="content"  style="display: none;">
												<div style="width:30vw">
													<ul>
														<li v-for="(remarkItem,remarkIndex) in detailItem.remark">{{remarkItem.remark}}</li>
													</ul>
												</div>
											</div>
										</button>
									</td>
									<td>{{detailItem.checker_name}}</td>
									<td>{{listItem.create_name}}<br><small>{{listItem.create_time}}</small></td>
									<td align="right">
										<button class="btn btn-sm btn-primary" data-toggle="modal" data-target="#process_startModal" @click="startProcess(listItem,detailItem,detailIndex,'get')" v-if="auth_ids.indexOf(328) != -1">开始处理</button>
										<!-- <button class="btn btn-sm btn-warning" data-toggle="modal" data-target="#process_pauseModal" @click="listPause(listIndex,detailItem)" v-if="auth_ids.indexOf(327) != -1">暂停</button> -->
									</td>
								</tr>
							</template>
						</template>
						<template v-else>
                            <tr style="text-align: center;" >
                                <td colspan="12" class="no_date" style="line-height: 20rem">{:lang('no_data')} </td>
                            </tr>
						</template>
					</tbody>
				</table>
			</div>

			<!-- 配货 加工 处理中 列表 -->
			<div class="col-md-12 tab-pane" id="process" v-if="requestType == 'process'">
				<table class="table table-striped table-hover ntTable">
					<thead>
						<tr>
							<th width="4%">No.</th>
							<th width="4%">时间</th>
							<th width="20%">产品</th>
							<th>箱规</th>
							<th width="4%">订单号</th>
							<th width="4%">优先</th>
							<th>数量</th>
							<th>合计</th>
							<th>备注</th>
							<th>库存</th>
							<th>组员</th>
							<th>编辑</th>
							<th>操作</th>
						</tr>
					</thead>
					<tbody>
						<template v-if="list != undefined && list.length > 0">
							<template v-for="(processItem,processIndex) in list">
								<tr v-for="(detailItem,detailIndex) in processItem.detail">
									<template v-if="detailIndex == 0">
										<td>{{ formatUnit(processItem.id,'id') }}</td>
										<td class="text-success main-list" :oldTime="processItem.create_at" align="center"><b></b></td>
										<td>
											<div class="pro">
												<div class="pro-icon">
													<img :src="detailItem.proInfo.img_url" border="0" width="48px" height="48px">
												</div>
												<div class="pro-name">
													<small>{{ formatUnit(detailItem.proInfo.prochar_id,'id') + (detailItem.proInfo.brand_name ? ' / ' + detailItem.proInfo.brand_name : '' ) + (detailItem.proInfo.model ? ' / ' + detailItem.proInfo.model : '') }}</small> <br />{{detailItem.proInfo.pro_name}}
												</div>
											</div>
										</td>
										<td align="right">
											{{formatUnit( detailItem.proInfo.prochar_qty,'PCS')}}<small class="unit">PCS/CTN</small><br>
											{{detailItem.proInfo.ctn_size}}<small class="unit">CM</small>
										</td>
									</template>
									<template v-else>
										<td></td>
										<td></td>
										<td></td>
										<td></td>
									</template>
									<td>{{ formatUnit(detailItem.sale_id,'id') }}</td>
									<td align="center"><span class="label label-primary">{{detailItem.priority}}</span></td>
									<td align="right">
										{{formatUnit( detailItem.qty,'PCS')}}<small class="unit">PCS</small>
									</td>
									<template v-if="detailIndex == 0">
										<td align="right">
											{{formatUnit( processItem.qtySum,'PCS')}}<small class="unit">PCS</small>
										</td>
									</template>
									<template v-else><td></td></template>
									
									<td>
										<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="备注"  @mouseover="setpopper">
											备注
											<div class="content" style="display: none;">
												<div style="width:30vw">
													<ul>
														<li v-for="(remarkItem,remarkIndex) in detailItem.remark">{{remarkItem.remark}}</li>
													</ul>
												</div>
											</div>
										</button>
									</td>
									<template v-if="detailIndex == 0">
										<td>
											<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="库存"  @mouseover="setpopper">
												库存
												<div class="content" style="display: none;">
													<div style="width:20vw">
														<table class="table">
															<tbody>
																<tr v-for="(storeInfoItem,storeInfoIndex) in detailItem.storeInfo">
																	<td>{{storeInfoItem.name}}</td>
																	<td align="right">
																		{{formatUnit( storeInfoItem.qty,'PCS')}}<small class="unit">PCS</small>
																	</td>
																</tr>
															</tbody>
														</table>
													</div>
												</div>
											</button>
										</td>
										<td>
											<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="组员"  @mouseover="setpopper">
												TEAM
												<div class="content" style="display: none;">
													<div style="width:20vw">
														{{processItem.team_names}}
													</div>
												</div>
											</button>
										</td>
										<td>{{processItem.create_name}}<br><small>{{processItem.create_time}}</small></td>
										<td align="right">
											<button class="btn btn-sm btn-default" data-toggle="modal" data-target="#process_viewModal" @click="processCheck(processItem,detailItem)" v-if="auth_ids.indexOf(329) != -1">查看</button>
											<button class="btn btn-sm btn-primary" data-toggle="modal" data-target="#process_pickupModal" @click="processPickup(processItem,detailItem)" v-if="auth_ids.indexOf(330) != -1">提货</button>
											<button class="btn btn-sm btn-warning" data-toggle="modal" data-target="#process_pauseModal" @click="processPause(processIndex,detailItem)" v-if="auth_ids.indexOf(327) != -1">暂停</button>
											<button class="btn btn-sm btn-primary" data-toggle="modal" data-target="#process_finishModal" @click=processFinish(processIndex,detailItem) v-if="auth_ids.indexOf(331) != -1">完成</button>
										</td>	
									</template>
								</tr>
							</template>
						</template>
						<template v-else>
                            <tr style="text-align: center;" >
                                <td colspan="13" class="no_date" style="line-height: 20rem">{:lang('no_data')} </td>
                            </tr>
						</template>
					</tbody>
				</table>
			</div>

			<!-- 配货 加工 提货中 列表 -->
			<div class="col-md-12 tab-pane" id="pickup" v-if="requestType == 'pickup'">
				<table class="table table-striped table-hover ntTable">
					<thead>
						<tr>
							<th width="4%">No.</th>
							<th width="4%">优先</th>
							<th width="4%">时间</th>
							<th width="20%">产品</th>
							<th>箱规</th>
							<th>库存</th>
							<th>数量</th>
							<th>目的地</th>
							<th>状态</th>
							<th>提货人</th>
							<th>编辑</th>
							<th>操作</th>
						</tr>
					</thead>
					<tbody>
						<template v-if="list != undefined && list.length > 0">
							<tr v-for="(listItem,listIndex) in list" >
								<td>{{ formatUnit(listItem.id,'id') }}</td>
								<td align="center"><span class="label label-info">{{listItem.priority}}</span></td>
								<td class="text-success main-list" :oldTime="listItem.create_at" align="center"><b></b></td>
								<td>
									<div class="pro">
										<div class="pro-icon">
											<img :src="listItem.proInfo.img_url" border="0" width="48px" height="48px">
										</div>
										<div class="pro-name">
											<small>{{ formatUnit(listItem.proInfo.prochar_id,'id') + (listItem.proInfo.brand_name ? ' / ' + listItem.proInfo.brand_name : '') + (listItem.proInfo.model ? ' / ' + listItem.proInfo.model : '') }}</small><br>
											{{listItem.proInfo.pro_name}}
										</div>
									</div>
								</td>
								<td align="right">
									{{formatUnit( listItem.proInfo.prochar_qty,'PCS')}}<small class="unit">PCS/CTN</small><br>
									{{listItem.proInfo.ctn_size}}<small class="unit">CM</small>
								</td>
								<td>
									<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="库存位置" @mouseover="setpopper">
										库存
										<div class="content" style="display: none;">
											<div style="width:12vw">
												<table class="table">
													<tbody>
														<template v-if="listItem.storeInfo.length > 0">
															<tr v-for="(storeInfoItem,storeInfoIndex) in listItem.storeInfo">
																<td>{{storeInfoItem.name}}</td>
																<td align="right">
																	{{formatUnit( storeInfoItem.qty,'PCS')}}<small class="unit">PCS</small>
																</td>	
															</tr>	
														</template>
														<template v-else>
															<tr>
																<td>-</td>
															</tr>	
														</template>
													</tbody>
												</table>
											</div>
										</div>
									</button>
								</td>
								<td align="right">
									<span class="text-primary f-1">{{ listItem.proInfo.prochar_qty > 0 ? listItem.qty/listItem.proInfo.prochar_qty : '-'}}</span><small class="unit">CTN</small><br>
									{{listItem.qty}}<small class="unit">PCS</small>
								</td>
								<td>{{listItem.area_name}}</td>
								<td>{{listItem.status_name}}</td>
								<td>{{listItem.checker_name}}</td>
								<td>
									{{listItem.create_name}}<br>
									<small>{{listItem.time}}</small>
								</td>
								<td align="right">
									<button class="btn btn-sm btn-warning" v-show="listItem.status_name == '-' && auth_ids.indexOf(333) != -1" @click="pickupCancel(listItem.id)" :disabled="isdisabled" >取消</button>
									<button class="btn btn-sm btn-primary" data-toggle="modal" data-target="#pickup_receivedModal" v-show="listItem.status_name == '完成' && listItem.received_at ==0 && auth_ids.indexOf(332) != -1" @click="pickupProcess('view',listItem)"  :disabled="isdisabled">收到</button>
								</td>
							</tr>
						</template>
						<template v-else>
                            <tr style="text-align: center;" >
                                <td colspan="12" class="no_date" style="line-height: 20rem">{:lang('no_data')} </td>
                            </tr>
						</template>
					</tbody>
				</table>
			</div>

			<!-- 配货 加工 暂停中 列表 -->
			<div class="col-md-12 tab-pane" id="pause" v-if="requestType == 'pause'">
				<table class="table table-striped table-hover ntTable">
					<thead>
						<tr>
							<th width="4%">No.</th>
							<th width="4%">时间</th>
							<th width="20%">产品</th>
							<th>箱规</th>
							<th width="4%">订单号</th>
							<th width="4%">优先</th>
							<th>数量</th>
							<th>合计</th>
							<th>备注</th>
							<th>库存</th>
							<th>组员</th>
							<th>编辑</th>
							<th>说明</th>
							<th>操作</th>
						</tr>
					</thead>
					<tbody>
						<template v-if="list != undefined && list.length > 0">
							<template v-for="(processItem,processIndex) in list">
								<tr v-for="(detailItem,detailIndex) in processItem.detail">
									<template v-if="detailIndex == 0">
										<td>{{ formatUnit(processItem.id,'id') }}</td>
										<td class="text-success main-list" :oldTime="processItem.create_at" align="center"><b></b></td>
										<td>
											<div class="pro">
												<div class="pro-icon">
													<img :src="detailItem.proInfo.img_url" border="0" width="48px" height="48px">
												</div>
												<div class="pro-name">
													<small>{{ formatUnit(detailItem.proInfo.prochar_id,'id') + (detailItem.proInfo.brand_name ? ' / ' + detailItem.proInfo.brand_name : '' ) + (detailItem.proInfo.model ? ' / ' + detailItem.proInfo.model : '') }}</small> <br />{{detailItem.proInfo.pro_name}}
												</div>
											</div>
										</td>
										<td align="right">
											{{formatUnit( detailItem.proInfo.prochar_qty,'PCS')}}<small class="unit">PCS/CTN</small><br>
											{{detailItem.proInfo.ctn_size}}<small class="unit">CM</small>
										</td>
									</template>
									<template v-else>
										<td></td>
										<td></td>
										<td></td>
										<td></td>
									</template>
									<td>{{ formatUnit(detailItem.sale_id,'id') }}</td>
									<td align="center"><span class="label label-primary">{{detailItem.priority}}</span></td>
									<td align="right">
										{{formatUnit( detailItem.qty,'PCS')}}<small class="unit">PCS</small>
									</td>
									<template v-if="detailIndex == 0">
										<td align="right">
											{{formatUnit( processItem.qtySum,'PCS')}}<small class="unit">PCS</small>
										</td>
									</template>
									<template v-else><td></td></template>
									
									<td>
										<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="备注"  @mouseover="setpopper">
											备注
											<div class="content" style="display: none;">
												<div style="width:30vw">
													<ul>
														<li v-for="(remarkItem,remarkIndex) in detailItem.remark">{{remarkItem.remark}}</li>
													</ul>
												</div>
											</div>
										</button>
									</td>
									<template v-if="detailIndex == 0">
										<td>
											<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="库存"  @mouseover="setpopper">
												库存
												<div class="content" style="display: none;">
													<div style="width:20vw">
														<table class="table">
															<tbody>
																<tr v-for="(storeInfoItem,storeInfoIndex) in detailItem.storeInfo">
																	<td>{{storeInfoItem.name}}</td>
																	<td align="right">
																		{{formatUnit( storeInfoItem.qty,'PCS')}}<small class="unit">PCS</small>
																	</td>
																</tr>
															</tbody>
														</table>
													</div>
												</div>
											</button>
										</td>
										<td>
											<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="组员"  @mouseover="setpopper">
												TEAM
												<div class="content" style="display: none;">
													<div style="width:20vw">
														{{processItem.team_names}}
													</div>
												</div>
											</button>
										</td>
										<td>{{processItem.create_name}}<br><small>{{processItem.create_time}}</small></td>
										<td>
											<button class="btn btn-sm btn-default" data-toggle="popover" title="暂停说明" @mouseover="setpopper">
												说明
												<div class="content" style="display: none;">
													<div style="width:25vw">
														<ul>
															<li v-for="(remarkItem,remarkIndex) in processItem.remark" >{{remarkItem.remark}}</li>
														</ul>
													</div>
												</div>
											</button>
										</td>
										<td align="right">
											<button class="btn btn-sm btn-default" data-toggle="modal" data-target="#process_viewModal" @click="processCheck(processItem,detailItem)" v-if="auth_ids.indexOf(329) != -1">查看</button>
										</td>
									</template>
								</tr>
							</template>
						</template>
						<template v-else>
                            <tr style="text-align: center;" >
                                <td colspan="14" class="no_date" style="line-height: 20rem">{:lang('no_data')} </td>
                            </tr>
						</template>
					</tbody>
				</table>
			</div>

			<!-- 配货 加工 完成中 列表 -->
			<div class="col-md-12 tab-pane" id="finish" v-if="requestType == 'finish'">
				<table class="table table-striped table-hover ntTable">
					<thead>
						<tr>
							<th width="4%">No.</th>
							<th width="20%">产品</th>
							<th>箱规</th>
							<th width="4%">订单号</th>
							<th width="4%">优先</th>
							<th>数量</th>
							<th>合计</th>
							<th>备注</th>
							<th>组员</th>
							<th>编辑</th>
							<th>完成</th>
							<th>操作</th>
						</tr>
					</thead>
					<tbody>
						<template v-if="list != undefined && list.length > 0">
							<template v-for="(processItem,processIndex) in list">
								<tr v-for="(detailItem,detailIndex) in processItem.detail">
									<template v-if="detailIndex == 0">
										<td>{{ formatUnit(processItem.id,'id') }}</td>
										<td>
											<div class="pro">
												<div class="pro-icon">
													<img :src="detailItem.proInfo.img_url" border="0" width="48px" height="48px">
												</div>
												<div class="pro-name">
													<small>{{ formatUnit(detailItem.proInfo.prochar_id,'id') + (detailItem.proInfo.brand_name ? ' / ' + detailItem.proInfo.brand_name : '' ) + (detailItem.proInfo.model ? ' / ' + detailItem.proInfo.model : '') }}</small> <br />{{detailItem.proInfo.pro_name}}
												</div>
											</div>
										</td>
										<td align="right">
											{{formatUnit( detailItem.proInfo.prochar_qty,'PCS')}}<small class="unit">PCS/CTN</small><br>
											{{detailItem.proInfo.ctn_size}}<small class="unit">CM</small>
										</td>
									</template>
									<template v-else>
										<td></td>
										<td></td>
										<td></td>
									</template>
									<td>{{ formatUnit(detailItem.sale_id,'id') }}</td>
									<td align="center"><span class="label label-primary">{{detailItem.priority}}</span></td>
									<td align="right">
										{{formatUnit( detailItem.qty,'PCS')}}<small class="unit">PCS</small>
									</td>
									<template v-if="detailIndex == 0">
										<td align="right">
											{{formatUnit( processItem.qtySum,'PCS')}}<small class="unit">PCS</small>
										</td>
									</template>
									<template v-else><td></td></template>
									
									<td>
										<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="备注"  @mouseover="setpopper">
											备注
											<div class="content" style="display: none;">
												<div style="width:30vw">
													<ul>
														<li v-for="(remarkItem,remarkIndex) in detailItem.remark">{{remarkItem.remark}}</li>
													</ul>
												</div>
											</div>
										</button>
									</td>
									<template v-if="detailIndex == 0">
										<td>
											<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="组员"  @mouseover="setpopper">
												TEAM
												<div class="content" style="display: none;">
													<div style="width:20vw">
														{{processItem.team_names}}
													</div>
												</div>
											</button>
										</td>
										<td>{{processItem.create_name}}<br><small>{{processItem.create_time}}</small></td>
										<td>{{processItem.finish_name}}<br><small>{{processItem.finish_time}}</small></td>
										<td align="right">
											<button class="btn btn-sm btn-default" data-toggle="modal" data-target="#process_viewModal" @click="processCheck(processItem,detailItem)" v-if="auth_ids.indexOf(329) != -1">查看</button>
											<button class="btn btn-sm btn-primary" @click="finishCancel(processItem.id,detailItem.proInfo.prochar_qty,detailItem.proInfo.ctn_m3)" :disabled="isdisabled" v-if="auth_ids.indexOf(334) != -1">取消完成</button>
										</td>	
									</template>
								</tr>
							</template>
						</template>
						<template v-else>
                            <tr style="text-align: center;" >
                                <td colspan="12" class="no_date" style="line-height: 20rem">{:lang('no_data')} </td>
                            </tr>
						</template>
					</tbody>
				</table>
			</div>

			<!-- 配货 加工 取消 列表 -->
			<div class="col-md-12 tab-pane" id="cancel" v-if="requestType == 'cancel'">
				<table class="table table-striped table-hover ntTable">
					<thead>
						<tr>
							<th width="4%">No.</th>
							<th width="20%">产品</th>
							<th>箱规</th>
							<th width="4%">订单号</th>
							<th width="4%">优先</th>
							<th>数量</th>
							<th>合计</th>
							<th>备注</th>
							<th>组员</th>
							<th>编辑</th>
							<th>取消</th>
							<th>操作</th>
						</tr>
					</thead>
					<tbody>
						<template v-if="list != undefined && list.length > 0">
							<template v-for="(processItem,processIndex) in list">
								<tr v-for="(detailItem,detailIndex) in processItem.detail">
									<template v-if="detailIndex == 0">
										<td>{{ formatUnit(processItem.id,'id') }}</td>
										<td>
											<div class="pro">
												<div class="pro-icon">
													<img :src="detailItem.proInfo.img_url" border="0" width="48px" height="48px">
												</div>
												<div class="pro-name">
													<small>{{ formatUnit(detailItem.proInfo.prochar_id,'id') + (detailItem.proInfo.brand_name ? ' / ' + detailItem.proInfo.brand_name : '' ) + (detailItem.proInfo.model ? ' / ' + detailItem.proInfo.model : '') }}</small> <br />{{detailItem.proInfo.pro_name}}
												</div>
											</div>
										</td>
										<td align="right">
											{{formatUnit( detailItem.proInfo.prochar_qty,'PCS')}}<small class="unit">PCS/CTN</small><br>
											{{detailItem.proInfo.ctn_size}}<small class="unit">CM</small>
										</td>
									</template>
									<template v-else>
										<td></td>
										<td></td>
										<td></td>
									</template>
									<td>{{ formatUnit(detailItem.sale_id,'id') }}</td>
									<td align="center"><span class="label label-primary">{{detailItem.priority}}</span></td>
									<td align="right">
										{{formatUnit( detailItem.qty,'PCS')}}<small class="unit">PCS</small>
									</td>
									<template v-if="detailIndex == 0">
										<td align="right">
											{{formatUnit( processItem.qtySum,'PCS')}}<small class="unit">PCS</small>
										</td>
									</template>
									<template v-else><td></td></template>
									
									<td>
										<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="备注"  @mouseover="setpopper">
											备注
											<div class="content" style="display: none;">
												<div style="width:30vw">
													<ul>
														<li v-for="(remarkItem,remarkIndex) in detailItem.remark">{{remarkItem.remark}}</li>
													</ul>
												</div>
											</div>
										</button>
									</td>
									<template v-if="detailIndex == 0">
										<td>
											<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="组员"  @mouseover="setpopper">
												TEAM
												<div class="content" style="display: none;">
													<div style="width:20vw">
														{{processItem.team_names}}
													</div>
												</div>
											</button>
										</td>
										<td>{{processItem.create_name}}<br><small>{{processItem.create_time}}</small></td>
										<td>{{processItem.cancel_name}}<br><small>{{processItem.cancel_time}}</small></td>
										<td align="right">
											<button class="btn btn-sm btn-default" data-toggle="modal" data-target="#process_viewModal" @click="processCheck(processItem,detailItem)" v-if="auth_ids.indexOf(329) != -1">查看</button>
										</td>	
									</template>
								</tr>
							</template>
						</template>
						<template v-else>
                            <tr style="text-align: center;" >
                                <td colspan="12" class="no_date" style="line-height: 20rem">{:lang('no_data')} </td>
                            </tr>
						</template>
					</tbody>
				</table>
			</div>
			
			<div class="col-md-12">
                <ul class="pagination" id="pagination" v-show="list.length!=0"></ul>
			</div>
	  </div>
	</div>

	<!-- 配货-加工 处理开始 弹窗开始 -->
	<div class="modal fade" id="process_startModal" tabindex="-1" role="dialog" aria-hidden="true">
	    <div class="modal-dialog modal-lg" style="width:70%">
	        <div class="modal-content">
	            <div class="modal-header">
	                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
	                <h4 class="modal-title">加工处理开始</h4>
	            </div>
	            <div class="modal-body">
	                <div class="row">
	                    <div class="col-md-12">
	                        <div class="alert alert-dismissable alert-info">
	                            <button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
	                            <p></p>
	                        </div>
	                    </div>
	                </div>
					<div class="row">
						<div class="col-md-9">
							<div class="row">
								<div class="col-md-12">
									<ul class="nav nav-tabs">
										<li class="active"><a href="#process_pro" data-toggle="tab">产品/配件</a></li>
										<li><a href="#process_sale" data-toggle="tab">加工订单</a></li>
									</ul>
								</div>
							</div>
							<div class="row tab-content">
								<!-- 加工 产品 -->
								<div class="col-md-12 tab-pane active" id="process_pro">
									<table class="table table-hover" style="margin-bottom: 0">
										<thead>
											<tr>
												<th width="50%">产品/配件</th>
												<th>箱规</th>
												<th>数量</th>
												<th>库存</th>
											</tr>
										</thead>
										<tbody>
											<tr>
												<td>
													<div class="pro">
														<div class="pro-icon">
															<img :src="startProcessData.proInfo.img_url" border="0" width="48px" height="48px">
														</div>
														<div class="pro-name">
															<small>{{ formatUnit(startProcessData.proInfo.prochar_id,'id') + (startProcessData.proInfo.brand_name ? ' / '+ startProcessData.proInfo.brand_name : '') + (startProcessData.proInfo.model ? ' / '+startProcessData.proInfo.model : '')  }}</small><br>
															{{startProcessData.proInfo.pro_name}}
														</div>
													</div>
												</td>
												<td align="right">
													{{formatUnit( startProcessData.proInfo.prochar_qty,'PCS')}}<small class="unit">PCS/CTN</small><br>
													{{startProcessData.proInfo.ctn_size}}<small class="unit">CM</small>
												</td>
												<td align="right">
													{{formatUnit( startProcessData.qty,'PCS')}}<small class="unit">PCS</small>
												</td>
												<td>
													<table class="table" style="margin-bottom: 0">
														<tbody>
															<tr v-for="(storeInfoItem,storeInfoIndex) in startProcessData.storeInfo">
																<td>{{storeInfoItem.name}}</td>
																<td align="right">{{formatUnit( storeInfoItem.qty,'PCS')}}<small class="unit">PCS</small></td>
															</tr>
														</tbody>
													</table>
												</td>
											</tr>
											<tr class="bg-warning">
												<td colspan="3" align="right">
													<span class="lh-3">
														订单数量合计 <span class="text-primary">{{formatUnit( startProcessData.qty,'PCS')}}</span><small class="unit">PCS</small>，需要处理数量为
													</span>
												</td>
												<td><input type="number" class="form-control text-right" id="inputProcessNum"  placeholder="加工的数量" @input="inputProcessNum(startProcessData,startProcessData.storeInfo)"></td>
											</tr>
											
											<tr v-for="(itemDataItem,itemDataItemIndex) in startProcessData.itemData">
												<td>
													<div class="pro" style="margin-left: 5rem">
														<div class="pro-icon">
															<input type="checkbox" checked>
														</div>
														<div class="pro-icon">
															<img :src="itemDataItem.img_url" border="0" width="48px" height="48px">
														</div>
														<div class="pro-name">
															<small>{{ (itemDataItem.prochar_id2item ? formatUnit(itemDataItem.prochar_id2item,'id') : formatUnit(itemDataItem.pro_id2item,'id'))+ (itemDataItem.brand_name ? ' / ' + itemDataItem.brand_name:'') + (itemDataItem.model ? ' / ' + itemDataItem.model : '') }}</small>
															<br>
															{{itemDataItem.itemName}}
														</div>
													</div>
												</td>
												<td align="right">
													{{formatUnit( itemDataItem.proInfo.prochar_qty,'PCS')}}<small class="unit">PCS/CTN</small><br>
													{{itemDataItem.proInfo.ctn_size}}<small class="unit">CM</small>
												</td>
												<td>
													<div class="itemPickupNum" style="display: none;" v-if="itemDataItem.pickupNum > 0">
														<label for="">提货数量</label>
														<input type="text" class="form-control text-right" v-model="itemDataItem.pickupNum" >
													</div>
												</td>
												<td>
													<table class="table" style="margin-bottom: 0">
														<tbody>
															<tr v-for="(storeInfoItem,storeInfoIndex) in itemDataItem.storeInfo">
																<td>{{storeInfoItem.name}}</td>
																<td align="right">{{formatUnit( storeInfoItem.qty,'PCS')}}<small class="unit">PCS</small></td>
															</tr>
														</tbody>
													</table>
												</td>
											</tr>
										</tbody>
									</table>
									<table class="table" v-if="pickupTableData.title != undefined">
										<tbody>
											<tr class="bg-warning">
												<td>
													{{pickupTableData.title}} 库存数量 <span class="green" id="">{{formatUnit( pickupTableData.storeSum,'PCS')}}</span><small class="unit">PCS</small> 少于要加工产品的数量 <span class="text-primary">{{formatUnit( pickupTableData.pickupQty,'PCS')}}</span><small class="unit">PCS</small>
												</td>
											</tr>
											<tr class="bg-warning">
												<td>
													<div class="row">
														<div class="col-md-2" @click="itemPickupNumIsShow()">
															&nbsp;<br>
															<button class="btn btn-default btn-checkbox">
																<input type="checkbox" name="pickupcheckbox">
																安排提货
															</button>
														</div>
														<div class="col-md-2">
															<small class="gray">优先级</small><br>
															<select name="" id="" class="form-control" v-model="pickupTableData.priority">
																<option value="0">选择优先级:</option>
																<!-- <option value="0">默认是订单优先级+2，最高为9</option> -->
																<option value="1">1</option>
																<option value="2">2</option>
																<option value="3">3</option>
																<option value="4">4</option>
																<option value="5">5</option>
																<option value="6">6</option>
																<option value="7">7</option>
																<option value="8">8</option>
																<option value="9">9</option>
															</select>
														</div>
														<div class="col-md-2">
															<small class="gray">提货</small><br>
															<div class="input-group">
																<input type="number" class="form-control text-right" placeholder="提货的数量" v-model="pickupTableData.pickupQty">
																<span class="input-group-addon"><small>CTN</small></span>
															</div>
														</div>
														<div class="col-md-2">
															<small class="gray">数量</small><br>
															<div class="lh-3">
																<small class="unit">PCS</small>
															</div>
														</div>
														<div class="col-md-4">
															<small class="gray">目的地</small><br>
															<select name="" id="destination" class="form-control" v-model="pickupTableData.store2area_id">
																<option value="0">请选择提货到</option>
																<option :value="destinationItem.store2area_id" v-for="(destinationItem,destinationIndex) in pickupTableData.destination">{{destinationItem.name}}</option>
															</select>
														</div>
													</div>
												</td>
											</tr>
										</tbody>
									</table>
								</div>
								<!-- 加工 订单 -->
								<div class="col-md-12 tab-pane" id="process_sale">
									<table class="table table-hover">
										<thead>
											<tr>
												<th width="4%">#</th>
												<th>订单号</th>
												<th>数量</th>
												<th width="60%">备注</th>
												<th>对货员</th>
											</tr>
										</thead>
										<tbody>
											<tr v-for="(startProcessData_Item,startProcessData_Index) in startProcessData_">
												<td align="center">{{startProcessData_Index + 1}}</td>
												<td align="center">{{ formatUnit(startProcessData_Item.sale_id,'id') }}</td>
												<td align="right">{{formatUnit( startProcessData_Item.qty,'PCS')}}<small class="unit">PCS</small></td>
												<td>
													<ul>
														<li v-for="(remarkItem,remarkIndex) in startProcessData_Item.remark">{{remarkItem.remark}}</li>
													</ul>
												</td>
												<td>{{startProcessData_Item.checker_name}}</td>
											</tr>
										</tbody>
										<tfoot>
											<tr>
												<td colspan="5">合计数量:  <span class="blue f-1">{{formatUnit( startProcessData.qty,'PCS')}}</span><small class="unit">PCS</small></td>
											</tr>
										</tfoot>
									</table>
								</div>
							</div>
						</div>
	                    <div class="col-md-3">
							<div class="row">
								<div class="col-md-12">
									<ul class="nav nav-tabs">
										<li class="active"><a href="#">指定员工</a></li>
									</ul>
								</div>
							</div>
							<div class="row">
								<div class="col-md-12 div-scroll" style="max-height:40vh">
									<!-- 参与员工 -->
									<div class="col-md-12" style="padding:0.2rem 0" v-for="(packerItem,packerIndex) in startProcessData.packer">
										<button class="btn btn-sm btn-default btn-checkbox col-md-12" style="text-align:left">
											<input type="checkbox" name="packer" :value='packerItem.id'> {{packerItem.nickname}}
											<span class="label label-info f-1 pull-right"> {{packerItem.workSum}}</span>
										</button>
									</div>
								</div>
							</div>
	                    </div>
	                </div>
				</div>
	            <div class="modal-footer">
	                <button type="button" class="btn btn-default" data-dismiss="modal"><span class="glyphicon glyphicon-remove"></span>取消</button>
	                <button type="button" class="btn btn-primary" style="padding-left:24px;padding-right:24px" @click="startProcess()">
						<span class="fa fa-cogs"></span>开始处理
					</button>
	            </div>
	        </div>
	    </div>
	</div>

	<!-- 配货-加工 暂停 弹窗开始 -->
	<div class="modal fade" id="process_pauseModal" tabindex="-1" role="dialog" aria-hidden="true">
	    <div class="modal-dialog modal-lg" style="width:60%">
	        <div class="modal-content">
	            <div class="modal-header">
	                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
	                <h4 class="modal-title">产品加工处理暂停</h4>
	            </div>
	            <div class="modal-body">
	                <div class="row">
	                    <div class="col-md-12">
	                        <div class="alert alert-dismissable alert-info">
	                            <button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
	                            <p></p>
	                        </div>
	                    </div>
	                </div>

					<div class="row">
					
						<!-- 加工暂停的产品 -->
						<div class="col-md-8">
							<div class="row">
								<div class="col-md-12">
									<ul class="nav nav-tabs">
										<li class="active"><a href="#">加工产品</a></li>
									</ul>
								</div>
							</div>
							<table class="table ntTable" style="margin-bottom: 0">
								<thead>
									<tr>
										<th width="50%">产品</th>
										<th>箱规</th>
										<th>库存</th>
										<th>加工数量</th>
									</tr>
								</thead>
								<tbody>
									<tr>
										<td>
											<div class="pro">
												<div class="pro-icon">
													<img :src="pauseData.proInfo.img_url" border="0" width="48px" height="48px">
												</div>
												<div class="pro-name">
													<small>{{ formatUnit(pauseData.proInfo.prochar_id,'id') + (pauseData.proInfo.brand_name ? ' / ' + pauseData.proInfo.brand_name : '' ) + (pauseData.proInfo.model ? ' / ' + pauseData.proInfo.model : '') }}</small><br>
													{{pauseData.proInfo.pro_name}}
												</div>
											</div>
										</td>
										<td align="right">
											{{formatUnit( pauseData.proInfo.prochar_qty,'PCS')}}<small class="unit">PCS/CTN</small><br>
											{{pauseData.proInfo.ctn_size}}<small class="unit">CM</small>
										</td>
										<td>
											<button class="btn btn-sm btn-default" data-toggle="popover" title="成品位置">
												库存
												<!-- <div class="content"> -->
													<div style="width:20vw">
														<table class="table">
															<tbody>
																<tr v-for="(pauseStoreItem,pauseStoreIndex) in pauseData.storeInfo">
																	<td>{{pauseStoreItem.name}}</td>
																	<td align="right">
																		{{formatUnit( pauseStoreItem.qty,'PCS')}}<small class="unit">PCS</small>
																	</td>
																</tr>
															</tbody>
															<tfoot>
																<tr>
																	<td>合计</td>
																	<td align="right">
																		{{formatUnit( pauseData.storeInfoQtySum,'PCS')}}<small class="unit">PCS</small>
																	</td>
																</tr>
															</tfoot>
														</table>
													</div>
												<!-- </div> -->
											</button>
										</td>
										<td align="right">
											<div class="lh-3">
												{{formatUnit( pauseData.processQty,'PCS')}}<small class="unit">PCS</small>
											</div>
										</td>
									</tr>
								</tbody>
							</table>
						</div>
						
						<!-- 右侧列表 -->
						<div class="col-md-4">
							<div class="row">
								<div class="col-md-12">
									<ul class="nav nav-tabs">
										<li class="active"><a href="#process_pause_item" data-toggle="tab">配件</a></li>
										<li><a href="#process_pause_sale" data-toggle="tab">影响订单</a></li>
									</ul>
									
									<div class="tab-content">
								
										<!-- 相关配件  列表 -->
										<div class="tab-pane active" id="process_pause_item">
											<table class="table ntTable">
												<thead>
													<tr>
														<th width="70%">配件</th>
														<th>库存</th>
													</tr>
												</thead>
												<tbody>
													<tr v-for="(pauseDataItem,pauseDataIndex) in  pauseData.itemData">
														<td>
															<div class="pro">
																<div class="pro-icon">
																	<img :src="pauseDataItem.proInfo.img_url" border="0" width="48px" height="48px">
																</div>
																<div class="pro-name">
																	<small>{{ formatUnit(pauseDataItem.proInfo.prochar_id,'id') + (pauseDataItem.proInfo.brand_name ? ' / ' + pauseDataItem.proInfo.brand_name : '') + (pauseDataItem.proInfo.model ? ' / ' + pauseDataItem.proInfo.model : '')   }} </small><br>
																	{{pauseDataItem.proInfo.pro_name}}
																</div>
															</div>
														</td>
														<td align="right">
															{{formatUnit( pauseDataItem.itemStoreSum,'PCS')}}<small class="unit">PCS</small>
														</td>
													</tr>
												</tbody>
											</table>
										</div>

										<!-- 影响订单列表 -->
										
										<div class="tab-pane" id="process_pause_sale">
											<table class="table ntTable">
												<thead>
													<tr>
														<th>订单号</th>
														<th>优先级</th>
														<th>数量</th>
														<th>备注</th>
													</tr>
												</thead>
												<tbody>
													<tr v-for="(saleDataItem,saleDataIndex) in pauseData.saleData">
														<td>{{ formatUnit(saleDataItem.sale_id,'id') }}</td>
														<td align="center"><span class="label label-info">{{saleDataItem.priority}}</span></td>
														<td align="right">{{formatUnit( saleDataItem.qty,'PCS')}}<small class="unit">PCS</small></td>
														<td align="right">
															<button class="btn btn-sm btn-default" data-toggle="popover" title="备注" @mouseover="setpopper">
																备注
																<div class="content" style="display: none;">
																	<div style="width:20vw">
																		<ul>
																			<li v-for="(remarkItem,remarkIndex) in saleDataItem.remark">{{remarkItem.remark}}</li>
																		</ul>
																	</div>
																</div>
															</button>
														</td>
													</tr>
												</tbody>
											</table>
										</div>
									</div>
									
								</div>
							</div>
						</div>
					
					</div>
				
					<div class="row">
						<div class="col-md-12">
							<div class="panel panel-warning">
								<div class="panel-heading">
									暂停说明 <span class="required"></span><br>
								</div>
								<div class="bg-warning" style="padding: 1rem">
									<input type="text" class="form-control" id="pauseRemark">
								</div>
							</div>
						</div>
					</div>
				
				</div>
	            <div class="modal-footer">
	                <button type="button" class="btn btn-default" data-dismiss="modal"><span class="glyphicon glyphicon-remove"></span>取消</button>
	                <button type="button" class="btn btn-warning" style="padding-left:24px;padding-right:24px" @click="saveProcessPause()" :disabled="isdisabled">
						<span class="fa fa-ban"></span>通知加工暂停
					</button>
	            </div>
	        </div>
	    </div>
	</div>

	<!-- 配货-加工 查看 弹窗开始 -->
	<div class="modal fade" id="process_viewModal" tabindex="-1" role="dialog" aria-hidden="true">
	    <div class="modal-dialog modal-lg" style="width:70%">
	        <div class="modal-content">
	            <div class="modal-header">
	                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
	                <h4 class="modal-title">配货加工处理查看</h4>
	            </div>
	            <div class="modal-body">
	                <div class="row">
	                    <div class="col-md-12">
	                        <div class="alert alert-dismissable alert-info">
	                            <button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
	                            <p></p>
	                        </div>
	                    </div>
	                </div>
					<div class="row">
						<div class="col-md-9">
							<div class="row">
								<div class="col-md-12">
									<ul class="nav nav-tabs">
										<li class="active"><a href="#view_pro" data-toggle="tab">产品/配件</a></li>
										<li><a href="#view_sale" data-toggle="tab">加工订单</a></li>
									</ul>
								</div>
							</div>
							<div class="row tab-content">
								<!-- 加工 产品 -->
								<div class="col-md-12 tab-pane active" id="view_pro">
									<table class="table table-hover" style="margin-bottom: 0">
										<thead>
											<tr>
												<th width="50%">产品/配件</th>
												<th>箱规</th>
												<th>数量</th>
												<th>库存使用</th>
											</tr>
										</thead>
										<tbody>
											<tr >
												<td>
													<div class="pro">
														<div class="pro-icon">
															<img :src="startProcessData.proInfo.img_url" border="0" width="48px" height="48px">
														</div>
														<div class="pro-name">
															<small>{{ formatUnit(startProcessData.proInfo.prochar_id,'id') + (startProcessData.proInfo.brand_name ? ' / ' + startProcessData.proInfo.brand_name : '') + (startProcessData.proInfo.model ? ' / ' + startProcessData.proInfo.model : '') }}</small><br>
															{{startProcessData.proInfo.pro_name}}
														</div>
													</div>
												</td>
												<td align="right">
													{{formatUnit( startProcessData.proInfo.prochar_qty,'PCS')}}<small class="unit">PCS/CTN</small><br>
													{{startProcessData.proInfo.ctn_size}}<small class="unit">CM</small>
												</td>
												<td align="right">
													<!-- <span class="green"> -->
													<!-- </span><small class="unit">PCS</small><br> -->
													
													{{formatUnit( startProcessData.qtySum,'PCS')}}<small class="unit">PCS</small>
												</td>
												<td>
													<table class="table" style="margin-bottom: 0" >
														<tbody>
															<tr v-for="(storeInfoItem,storeInfoIndex) in startProcessData.storeInfo">
																<td>{{storeInfoItem.name}}</td>
																<td align="right">
																	<span class="red">{{formatUnit( storeInfoItem.qty,'PCS')}}</span><small class="unit">PCS</small>
																</td>
															</tr>
														</tbody>
													</table>
												</td>
											</tr>
											<tr v-for="(itemDataItem,itemDataItemIndex) in startProcessData.itemData">
												<td>
													<div class="pro" style="margin-left: 5rem">
														<div class="pro-icon">
															<img :src="itemDataItem.proInfo.img_url" border="0" width="48px" height="48px">
														</div>
														<div class="pro-name">
															<small>{{ formatUnit(itemDataItem.proInfo.prochar_id,'id') + (itemDataItem.proInfo.brand_name ? ' / ' + itemDataItem.proInfo.brand_name : '') + (itemDataItem.proInfo.model ? ' / ' + itemDataItem.proInfo.model : '')   }} </small><br>
															{{itemDataItem.proInfo.pro_name}}
														</div>
													</div>
												</td>
												<td align="right">
													{{formatUnit( itemDataItem.proInfo.prochar_qty,'PCS')}}<small class="unit">PCS/CTN</small><br>
													{{itemDataItem.proInfo.ctn_size}}<small class="unit">CM</small>
												</td>
												<td></td>
												<td>
													<table class="table" style="margin-bottom: 0">
														<tbody>
															<tr v-for="(storeInfoItem,storeInfoIndex) in itemDataItem.storeInfo">
																<td>{{storeInfoItem.name}}</td>
																<td align="right">
																	<span class="red">{{formatUnit( storeInfoItem.qty,'PCS')}}</span><small class="unit">PCS</small>
																</td>
															</tr>
														</tbody>
													</table>
												</td>
											</tr>
										</tbody>
									</table>
								</div>
								<!-- 加工 订单 -->
								<div class="col-md-12 tab-pane" id="view_sale">
									<table class="table table-hover">
										<thead>
											<tr>
												<th width="4%">#</th>
												<th>订单号</th>
												<th>数量</th>
												<th width="60%">备注</th>
												<th>对货员</th>
											</tr>
										</thead>
										<tbody>
											<tr v-for="(startProcessData_Item,startProcessData_Index) in startProcessData_">
												<td align="center">{{startProcessData_Index + 1}}</td>
												<td align="center">{{ formatUnit(startProcessData_Item.sale_id,'id') }}</td>
												<td align="right">{{formatUnit( startProcessData_Item.qty,'PCS')}}<small class="unit">PCS</small></td>
												<td>
													<ul>
														<li v-for="(remarkItem,remarkIndex) in startProcessData_Item.remark">{{remarkItem.remark}}</li>
													</ul>
												</td>
												<td>{{startProcessData_Item.checker_name}}</td>
											</tr>
										</tbody>
										<tfoot>
											<tr>
												<td colspan="5">合计数量: <span class="blue f-1">{{formatUnit( startProcessData.qtySum,'PCS')}}</span><small class="unit">PCS</small></td>
											</tr>
										</tfoot>
									</table>
								</div>
							</div>
						</div>
	                    <div class="col-md-3">
							<div class="row">
								<div class="col-md-12">
									<ul class="nav nav-tabs">
										<li class="active"><a href="#view_states" data-toggle="tab">状态</a></li>
										<li><a href="#view_team" data-toggle="tab">组员</a></li>
									</ul>
								</div>
							</div>
							<div class="row">
								<div class="col-md-12">
									<div class="tab-content">
										<div class="tab-pane active" id="view_states">
											<!-- 处理状态 -->
											<table class="table" style="margin-top: 1rem">
												<tbody>
													<tr>
														<td>状态</td>
														<td>{{ startProcessData.cancel_name ? '取消中' : startProcessData.finish_name ? '完成' : startProcessData.pause_name ? '暂停中' : '等待中' }}</td>
													</tr>
													<tr>
														<td>开始</td>
														<td>
															{{startProcessData.start_name}}<br>
															<small>{{startProcessData.start_time}}</small>
														</td>
													</tr>
													<tr>
														<td>暂停</td>
														<td v-if="startProcessData.pause_name">
															{{startProcessData.pause_name}}<br>
															<small>{{startProcessData.pause_time}}</small><br>
															<button class="btn btn-sm btn-default" data-toggle="popover" title="暂停说明" @mouseover="setpopper">
																说明
																<div class="content" style="display: none;">
																	<div style="width:20vw">
																		<ul>
																			<li v-for="(listRemarkItem,listRemarkIndex) in startProcessData.listRemark">{{listRemarkItem.remark}}</li>
																		</ul>
																	</div>
																</div>
															</button>
														</td>
													</tr>
													<tr>
														<td>完成</td>
														<td>
															{{startProcessData.finish_name}}<br>
															<small>{{startProcessData.finish_time}}</small>
														</td>
													</tr>
													<tr>
														<td>取消</td>
														<td>
															{{startProcessData.cancel_name}}<br>
															<small>{{startProcessData.cancel_time}}</small>
														</td>
													</tr>
												</tbody>
											</table>
										</div>
										<div class="tab-pane" id="view_team" style="padding: 1rem">
											<!-- 参与员工 -->
											<ul class="list-group">
												<li class="list-group-item" v-for="(team_nameDataItem,team_nameDataIndex) in startProcessData.team_nameData">{{team_nameDataItem}}</li>
											</ul>
										</div>
									</div>
								</div>
							</div>
	                    </div>
	                </div>
				</div>
	            <div class="modal-footer">
	                <button type="button" class="btn btn-default" data-dismiss="modal"><span class="glyphicon glyphicon-remove"></span>取消</button>
	            </div>
	        </div>
	    </div>
	</div>

	<!-- 配货-加工 提货 弹窗开始 -->
	<div class="modal fade" id="process_pickupModal" tabindex="-1" role="dialog" aria-hidden="true">
	    <div class="modal-dialog modal-lg" style="width:60%">
	        <div class="modal-content">
	            <div class="modal-header">
	                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
	                <h4 class="modal-title">包装部提货</h4>
	            </div>
	            <div class="modal-body">
	                <div class="row">
	                    <div class="col-md-12">
	                        <div class="alert alert-dismissable alert-info">
	                            <button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
	                            <p></p>
	                        </div>
	                    </div>
	                </div>
					<div class="row">
						<div class="col-md-offset-5 col-md-2">
							<small class="gray">优先级<span class="required"></span></small><br>
							<select name="" id="processPickupPriority" class="form-control">
								<option value="1">1</option>
								<option value="2">2</option>
								<option value="3" selected>3</option>
								<option value="4">4</option>
								<option value="5">5</option>
								<option value="6">6</option>
								<option value="7">7</option>
								<option value="8">8</option>
								<option value="9">9</option>
							</select>
						</div>
						<div class="col-md-5">
							<small class="gray">目的地<span class="required"></span></small><br>
							<select name="" id="processPickupArea_id" class="form-control">
								<option value="0">请选择提货到</option>
								<option :value="storeInfoProcessPickupItem.id" v-for="(storeInfoProcessPickupItem,storeInfoProcessPickupIndex) in processPickupData.storeInfo">{{storeInfoProcessPickupItem.name}}</option>
							</select>
						</div>
					</div>
					<div class="row">
						<div class="col-md-12">
							<table class="table ntTable">
								<thead>
									<tr>
										<th width="40%">产品</th>
										<th width="15%">箱规</th>
										<th>库存</th>
										<th width="8%">加工数量</th>
										<th width="15%">提货<span class="required"></span></th>
										<th>数量</th>
									</tr>
								</thead>
								<tbody>
									<tr>
										<td>
											<div class="pro">
												<div class="pro-icon">
													<img :src="processPickupData.proInfo.img_url" border="0" width="48px" height="48px">
												</div>
												<div class="pro-name">
													<small>{{ formatUnit(processPickupData.proInfo.prochar_id,'id') + (processPickupData.proInfo.brand_name ? ' / ' + processPickupData.proInfo.brand_name : '') + (processPickupData.proInfo.model ? ' / ' + processPickupData.proInfo.model : '' ) }} </small><br>
													{{processPickupData.proInfo.pro_name}}
												</div>
											</div>
										</td>
										<td align="right">
											{{formatUnit( processPickupData.proInfo.prochar_qty,'PCS')}}<small class="unit">PCS/CTN</small><br>
											{{processPickupData.proInfo.ctn_size}}<small class="unit">CM</small>
										</td>
										<td>
											<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="成品位置" @mouseover="setpopper">
												库存
												<!-- <div class="content"> -->
													<div style="width:15vw" >
														<table class="table">
															<tbody>
																<tr v-for="(storeInfoProcessPickupItem,storeInfoProcessPickupIndex) in processPickupData.storeInfo">
																	<td>{{storeInfoProcessPickupItem.name}}</td>
																	<td align="right">
																		{{formatUnit( storeInfoProcessPickupItem.qty,'PCS')}}<small class="unit">PCS</small>
																	</td>
																</tr>
															</tbody>
															<tfoot>
																<tr>
																	<td>合计</td>
																	<td align="right">
																		{{formatUnit( processPickupData.storeInfoQtySum,'PCS')}}<small class="unit">PCS</small>
																	</td>
																</tr>
															</tfoot>
														</table>
													</div>
												<!-- </div> -->
											</button>

										</td>
										<td align="right">
											<div class="lh-3">
												{{formatUnit( processPickupData.processQty,'PCS')}}<small class="unit">PCS</small>
											</div>
										</td>
										<td>
											<div class="input-group">
												<input type="number" class="form-control text-right" value="0" @input="processPickupInput(processPickupData)" id="processPickup">
												<span class="input-group-addon"><small>CTN</small></span>
											</div>
										</td>
										<td align="right">
											<div class="lh-3" id="processPickupQty">
												<small class="unit">PCS</small>
											</div>
										</td>
									</tr>
								</tbody>
							</table>
						</div>
					</div>
					
				</div>
	            <div class="modal-footer">
	                <button type="button" class="btn btn-default" data-dismiss="modal"><span class="glyphicon glyphicon-remove"></span>取消</button>
	                <button type="button" class="btn btn-primary" style="padding-left:24px;padding-right:24px" @click="processPickup('save','')" :disabled="isdisabled">
						<span class="fa fa-dolly-flatbed"></span>通知提货
					</button>
	            </div>
	        </div>
	    </div>
	</div>
	<!-- 配货-加工 提货收到确认 弹窗开始 -->
	<div class="modal fade" id="pickup_receivedModal" tabindex="-1" role="dialog" aria-hidden="true">
	    <div class="modal-dialog modal-lg" style="width:70%">
	        <div class="modal-content">
	            <div class="modal-header">
	                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
	                <h4 class="modal-title">提货收到确认</h4>
	            </div>
	            <div class="modal-body">
	                <div class="row">
	                    <div class="col-md-12">
	                        <div class="alert alert-dismissable alert-info">
	                            <button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
	                            <p></p>
	                        </div>
	                    </div>
	                </div>
					<div class="row">
						<div class="col-md-12">
							<table class="table table-striped table-hover ntTable">
								<thead>
									<tr>
										<th width="4%">No.</th>
										<th width="4%">优先</th>
										<th width="20%">产品</th>
										<th>箱规</th>
										<th>库存</th>
										<th>数量</th>
										<th>目的地</th>
										<th>提货人</th>
										<th>编辑</th>
									</tr>
								</thead>
								<tbody>
									<tr>
										<td>6667</td>
										<td align="center"><span class="label label-info">5</span></td>
										<td>
											<div class="pro">
												<div class="pro-icon">
													<img :src="pickupProcessData.proInfo.img_url" border="0" width="48px" height="48px">
												</div>
												<div class="pro-name">
													<small>{{ formatUnit(pickupProcessData.proInfo.prochar_id,'id') + (pickupProcessData.proInfo.brand_name ? ' / ' + pickupProcessData.proInfo.brand_name : '') + (pickupProcessData.proInfo.model ? ' / ' + pickupProcessData.proInfo.model : '') }}</small><br>
													{{pickupProcessData.proInfo.pro_name}}
												</div>
											</div>
										</td>
										<td align="right">
											{{formatUnit( pickupProcessData.proInfo.prochar_qty,'PCS')}}<small class="unit">PCS/CTN</small><br>
											{{pickupProcessData.proInfo.ctn_size}}<small class="unit">CM</small>
										</td>
										<td>
											<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="库存位置">
												库存
												<div class="content">
													<div style="width:12vw">
														<table class="table">
															<tbody>
																<template v-if="pickupProcessData.storeInfo.length > 0">
																	<tr v-for="(storeInfoItem,storeInfoIndex) in pickupProcessData.storeInfo">
																		<td>{{storeInfoItem.name}}</td>
																		<td align="right">
																			{{formatUnit( storeInfoItem.qty,'PCS')}}<small class="unit">PCS</small>
																		</td>	
																	</tr>	
																</template>
																<template v-else>
																	<tr>
																		<td>-</td>
																	</tr>	
																</template>
															</tbody>
														</table>
													</div>
												</div>
											</button>
										</td>
										<td align="right">
											<span class="text-primary f-1">{{ pickupProcessData.proInfo.prochar_qty > 0 ? pickupProcessData.qty/pickupProcessData.proInfo.prochar_qty : '-'}}</span><small class="unit">CTN</small><br>
											{{pickupProcessData.qty}}<small class="unit">PCS</small>
										</td>
										<td>{{pickupProcessData.area_name}}</td>
										<td>{{pickupProcessData.checker_name}}</td>
										<td>
											{{pickupProcessData.create_name}}<br>
											<small>{{pickupProcessData.time}}</small>
										</td>
									</tr>
								</tbody>
							</table>
						</div>
	                </div>
				</div>
	            <div class="modal-footer">
	                <button type="button" class="btn btn-default" data-dismiss="modal"><span class="glyphicon glyphicon-remove"></span>取消</button>
	                <button type="button" class="btn btn-primary" style="padding-left:24px;padding-right:24px" @click="pickupProcess('save','')">
						<span class="fa fa-dolly-flatbed"></span>确认以上产品已经收到
					</button>
	            </div>
	        </div>
	    </div>
	</div>

	<!-- 配货-加工 处理完成 弹窗开始 -->
	<div class="modal fade" id="process_finishModal" tabindex="-1" role="dialog" aria-hidden="true">
	    <div class="modal-dialog modal-lg" style="width:70%">
	        <div class="modal-content">
	            <div class="modal-header">
	                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
	                <h4 class="modal-title">加工处理完成</h4>
	            </div>
	            <div class="modal-body">
	                <div class="row">
	                    <div class="col-md-12">
	                        <div class="alert alert-dismissable alert-info">
	                            <button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
	                            <p></p>
	                        </div>
	                    </div>
	                </div>
					<div class="row">
						<div class="col-md-12">
							<div class="row">
								<div class="col-md-12">
									<ul class="nav nav-tabs">
										<li class="active"><a href="#process_finish_pro" data-toggle="tab">产品</a></li>
										<li><a href="#process_finish_sale" data-toggle="tab">加工订单</a></li>
									</ul>
								</div>
							</div>
							<div class="row tab-content">
								
							
								<!-- 加工 产品 -->
								<div class="col-md-12 tab-pane active" id="process_finish_pro">
									<div class="div-scroll" style="max-height:40vh">
										<table class="table table-hover">
											<thead>
												<tr>
													<th width="40%">产品/配件</th>
													<th>箱规</th>
													<th>数量</th>
													<th>使用库存</th>
												</tr>
											</thead>
											<tbody>
												<tr>
													<td>
														<div class="pro">
															<div class="pro-icon">
																<img :src="processFinishData.proInfo.img_url" border="0" width="48px" height="48px">
															</div>
															<div class="pro-name">
																<small>{{ formatUnit(processFinishData.proInfo.prochar_id,'id') + (processFinishData.proInfo.brand_name ? ' / ' + processFinishData.proInfo.brand_name : '') + (processFinishData.proInfo.model ? ' / ' + processFinishData.proInfo.model : '' ) }}</small><br>{{processFinishData.proInfo.pro_name}}
															</div>
														</div>
													</td>
													<td align="right">
														{{formatUnit( processFinishData.proInfo.prochar_qty,'PCS')}}<small class="unit">PCS/CTN</small><br>
														{{processFinishData.proInfo.ctn_size}}<small class="unit">CM</small>
													</td>
													<td align="right">
														{{processFinishData.qtySum}}<small class="unit">PCS</small>
													</td>
													<td>
														<table class="table" style="margin-bottom: 0">
															<tbody>
																<tr v-for="(storeInfoItem,storeInfoIndex) in processFinishData.storeInfo">
																	<td><input type="checkbox" checked name="processFinishchecked" :store2area_id='storeInfoItem.store2area_id' :qty="storeInfoItem.qty" :area_id="storeInfoItem.id"></td>
																	<td>{{storeInfoItem.name}}</td>
																	<td align="right">{{formatUnit( storeInfoItem.qty,'PCS')}}<small class="unit">PCS</small></td>
																</tr>
															</tbody>
														</table>
													</td>
												</tr>
												<!-- 配件 start  -->
												<tr v-for="(itemDataItem,itemDataIndex) in processFinishData.itemData">
													<td>
														<div class="pro">
															<div class="pro-icon">
																<img :src="itemDataItem.proInfo.img_url" border="0" width="48px" height="48px">
															</div>
															<div class="pro-name">
																<small>{{ formatUnit(itemDataItem.proInfo.prochar_id,'id') + (itemDataItem.proInfo.brand_name ? ' / ' + itemDataItem.proInfo.brand_name : '') + (itemDataItem.proInfo.model ? ' / ' + itemDataItem.proInfo.model : '' ) }}</small><br>{{itemDataItem.proInfo.pro_name}}
															</div>
														</div>
													</td>
													<td align="right">
														{{formatUnit( itemDataItem.proInfo.prochar_qty,'PCS')}}<small class="unit">PCS/CTN</small><br>
														{{itemDataItem.proInfo.ctn_size}}<small class="unit">CM</small>
													</td>
													<td></td>
													<td>
														<table class="table" style="margin-bottom: 0">
															<tbody>
																<tr v-for="(storeInfoItem,storeInfoIndex) in itemDataItem.storeInfo">
																	<td><input type="checkbox" checked :name="'processFinishItemchecked_'+itemDataIndex" :store2area_id="storeInfoItem.store2area_id" :qty="storeInfoItem.qty" :area_id="storeInfoItem.id"></td>
																	<td>{{storeInfoItem.name}}</td>
																	<td align="right">{{formatUnit( storeInfoItem.qty,'PCS')}}<small class="unit">PCS</small></td>
																</tr>
															</tbody>
														</table>
													</td>
												</tr>
												<!-- 配件 end  -->
											</tbody>
										</table>
									</div>
									
									<table class="table table-hover">
										<thead>
											<tr>
												<th>组员</th>
												<th>加工数量</th>
												<th>成品数量</th>
												<th>订单数量</th>
												<th width="15%">剩余数量</th>
												<th width="25%">剩余存放</th>
											</tr>
										</thead>
										<tbody>
											<tr class="bg-warning">
												<td>
													<button class="btn btn-sm btn-default" data-toggle="popover" placement="right" title="组员">
														TEAM
														<!-- <div class="content"> -->
															<div style="width:20vw">
																{{processFinishData.team_names}}
															</div>
														<!-- </div> -->
													</button>
												</td>
												<td align="right">
													<span class="lh-3">
														<span class="text-primary">{{formatUnit( processFinishData.processQty,'PCS')}}</span><small class="unit">PCS</small>
													</span>
												</td>
												<td align="right">
													<span class="lh-3">
														{{formatUnit( processFinishData.okSum,'PCS')}}<small class="unit">PCS</small>
													</span>
												</td>
												<td align="right">
													<span class="lh-3">
														<span class="text-primary">{{formatUnit( processFinishData.qtySum,'PCS')}}</span><small class="unit">PCS</small>
													</span>
												</td>
												<td>
													<input type="number" class="form-control text-right" placeholder="剩余的数量" id="finishSaveQty"  :value="processFinishData.processQty+processFinishData.okSum-processFinishData.qtySum ">
												</td>
												<td>
													<select name="" class="form-control" id="processFinishStore2area_id">
														<option value="">请选择存放位置</option>
														<option :value="storeInfoIndex" v-for="(storeInfoItem,storeInfoIndex) in processFinishData.storeInfo">{{storeInfoItem.name}}</option>
													</select>
												</td>
											</tr>
										</tbody>
									</table>
								</div>
								
								<!-- 加工 订单 -->
								<div class="col-md-12 tab-pane" id="process_finish_sale">
									<table class="table table-hover">
										<thead>
											<tr>
												<th width="4%">#</th>
												<th>订单号</th>
												<th>数量</th>
												<th width="60%">备注</th>
												<th>对货员</th>
											</tr>
										</thead>
										<tbody>

											<tr v-for="(startProcessData_Item,startProcessData_Index) in startProcessData_">
												<td align="center">{{startProcessData_Index + 1}}</td>
												<td align="center">{{ formatUnit(startProcessData_Item.sale_id,'id') }}</td>
												<td align="right">{{formatUnit( startProcessData_Item.qty,'PCS')}}<small class="unit">PCS</small></td>
												<td>
													<ul>
														<li v-for="(remarkItem,remarkIndex) in startProcessData_Item.remark">{{remarkItem.remark}}</li>
													</ul>
												</td>
												<td>{{startProcessData_Item.checker_name}}</td>
											</tr>
										</tbody>
										<tfoot>
											<tr>
												<td colspan="5">合计数量:  <span class="blue f-1">{{formatUnit( processFinishData.saleQty,'PCS')}}</span><small class="unit">PCS</small></td>
											</tr>
										</tfoot>
									</table>
								</div>
							</div>
						</div>
	                </div>
				</div>
	            <div class="modal-footer">
	                <button type="button" class="btn btn-default" data-dismiss="modal"><span class="glyphicon glyphicon-remove"></span>取消</button>
	                <button type="button" class="btn btn-primary" style="padding-left:24px;padding-right:24px" @click="processFinish('','','save')"  :disabled="isdisabled">
						<span class="fa fa-cogs"></span>完成加工
					</button>
	            </div>
	        </div>
	    </div>
	</div>
</div>

<script type="text/javascript">
  	setInterval(function() {
  		var data = $('.main-list');
        $.each(data, (key, value) => {
        	var time = Date.parse(new Date())/1000 - $('.main-list').eq(key).attr('oldTime');
        	var s = 0	// 秒
        	var m = 0	// 分
        	var h = 0	// 时
        	if(time > 59 ){
        		s = time%60;	// 取余
        		if(s < 10) s= '0'+ s
        		m = Math.floor(time/60)
        		if(m >= 60 ) m = (m%60)
        		if(m < 10) m= '0'+ m
        		h = Math.floor(time/3600)
        		if(h < 10) h= '0'+ h
        	}
        	// console.log(h+':'+m+":"+s)
        	$('.main-list').eq(key).text( h+':'+m+":"+s );
        })
  	}, 1000);
</script>
<script type="text/javascript" src="/static/Admin/js/salepacker.js"></script>
{include file="public/foot"/}

